﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using DevExpress.XtraEditors;
using System.Resources;

namespace CRM.GUI.QLKhachHang
{
    public partial class frmUpdate : DevExpress.XtraEditors.XtraForm
    {
        public frmUpdate()
        {
            InitializeComponent();
            ExpandAndCollapse();
        }
        private int _Check = 0;
        private void btnExpand_Click(object sender, EventArgs e)
        {
            ExpandAndCollapse();
        }

        private void ExpandAndCollapse()
        {
            if (_Check == 0)
            {
                flowLayoutPanel1.Height = 368 - 80;
                this.Height = 472 - 80;
                groupBox2.Visible = false;
                btnExpand.Text = "Chi Tiết";
                btnExpand.Image = global::CRM.Properties.Resources.Expand;
                _Check = 1;
            }
            else if (_Check == 1)
            {
                flowLayoutPanel1.Height = 368;
                this.Height = 472;
                groupBox2.Visible = true;
                btnExpand.Text = "Thu Nhỏ";
                btnExpand.Image = global::CRM.Properties.Resources.Collapse;
                _Check = 0;
            }
        }
    }
}